<?php
class UserModel extends Model{
	public function __construct()
	{
		parent::__construct();
		$this->tableName = "users";
		$this->formMapping = array(
			'uid'=>'uid',
			'email'=>'email',
			'password'=>'password',
			'truename'=>'truename',
			'regdate'=>'regdate',
			'sex'=>'sex',
			'birth_year'=>'birth_year',
			'birth_month'=>'birth_month',
			'birth_day'=>'birth_day',
			'home_province'=>'home_province',
			'home_city'=>'home_city',
			'qq_number'=>'qq_number',
			'msn_account'=>'msn_account',
			'cellphone'=>'cellphone',
			'telephone'=>'telephone',
			'homepage'=>'homepage',
			'school_id'=>'school_id',
			'department_id'=>'department_id',
			'company_name'=>'company_name',
			'company_description'=>'company_description',
			'business'=>'business',
			'position'=>'position',
			'career_start'=>'career_start',
			'photo_url'=>'photo_url',
			'score'=>'score',
			'user_type'=>'user_type',
			'privacy' => 'privacy',
			'degree' => 'degree'
			);
	}
	public function __toString()
	{
		$string = "";
		foreach($this->data as $key => $value)
		{
			$string .= $key . " => " . $value . "\n";
		}
		return $string;
	}
};
?>
